<div class="bs-callout bs-callout-info">
    <h4>Socials</h4>
</div>

<form class="form-horizontal" role="form" method="POST">
    <div class="form-group">
        <label for="logo" class="col-sm-2 control-label">Logo</label>
        <div class="col-sm-8">
            <input type="text" class="form-control" id="logo" placeholder="Logo" name="logo" required="true" value="<?php echo $data['logo'];?>" />
        </div>
        <div class="col-sm-2">
            <input type="button" id="btnSelectImg" class="btn btn-primary" value="Browse server" />
        </div>
    </div>
    
    <div class="form-group">
        <label for="facebook" class="col-sm-2 control-label">Link facebook</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="facebook" placeholder="facebook" name="facebook" required="true" value="<?php echo $data['facebook'];?>" />
        </div>
    </div>
    
    <div class="form-group">
        <label for="googleplus" class="col-sm-2 control-label">Link google plus</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="googleplus" placeholder="googleplus" name="googleplus" required="true" value="<?php echo $data['googleplus'];?>" />
        </div>
    </div>
    
    <div class="form-group">
        <label for="twitter" class="col-sm-2 control-label">Link twitter</label>
        <div class="col-sm-4">
            <input type="text" class="form-control" id="twitter" placeholder="twitter" name="twitter" required="true" value="<?php echo $data['twitter'];?>" />
        </div>
        <label for="widget_id" class="col-sm-2 control-label">Widget ID of twitter</label>
        <div class="col-sm-4">
            <input type="text" class="form-control" id="widget_id" placeholder="Eg: 416490410626662400" name="widget_id" required="true" value="<?php echo $data['widget_id'];?>" />
        </div>
        <div class="col-sm-8"></div>
        <div class="col-sm-4">
            <a href="http://blog.topdevs.net/2013/06/19/where-to-find-twitter-widget-id/" target="_blank">Where to find Twitter widget ID?</a>
        </div>
    </div>
    
    <div class="form-group">
        <label for="skype" class="col-sm-2 control-label">Skype</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="skype" placeholder="skype" name="skype" required="true" value="<?php echo $data['skype'];?>" />
        </div>
    </div>
    
    <div class="form-group">
        <label for="email" class="col-sm-2 control-label">Email contact</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="email" placeholder="Email" name="email" required="true" value="<?php echo $data['email'];?>" />
        </div>
    </div>
    
    <div class="form-group">
        <label for="phone" class="col-sm-2 control-label">Phone</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="phone" placeholder="Phone" name="phone" required="true" value="<?php echo $data['phone'];?>" />
        </div>
    </div>
    
    <div class="form-group">
        <label for="address" class="col-sm-2 control-label">Address</label>
        <div class="col-sm-10">
            <input type="text" class="form-control" id="address" placeholder="Address" name="address" required="true" value="<?php echo $data['address'];?>" />
        </div>
    </div>
    
    <div class="form-group">
        <div class="col-sm-offset-2 col-sm-10">
            <button type="submit" class="btn btn-primary">Save</button>
        </div>
    </div>
</form> 

<script type="text/javascript">
function redirectlink(url){
    window.location.href=url;
}
    $(document).ready(function () {
        $("#btnSelectImg").click(function () {
            var finder = new CKFinder();
            finder.selectActionFunction = function (fileUrl) {
                $('#logo').val(fileUrl);
            };
            finder.popup();
        });
    });
</script> 